home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Shareware Overload Trio 2
/
Shareware Overload Trio Volume 2 (Chestnut CD-ROM).ISO
/
dir30
/
drftls.zip
/
!MANUAL.TXT
< prev
next >
Wrap
Text File
|
1993-11-21
|
42KB
|
927 lines
DrafTools(tm) for AutoCAD(tm)* --
Installation & Operation Manual
For Custom Title Block Management Routines
Version 1.00
Copyright 1993 Owen Wengerd
Manu-Soft Computer Services
by Owen Wengerd
Printed 10/03/93
* AutoCAD, ACAD, AutoLISP, and ADS are trademarks of Autodesk, Inc.
============== DrafTools(tm) Installation & Operation Manual 2
DISCLAIMER - AGREEMENT
Users of DrafTools(tm) must accept this disclaimer of warranty:
"DrafTools(tm) is supplied as is. The author disclaims all warranties,
expressed or implied, including, without limitation, the warranties of
merchantability and of fitness for any purpose. The author assumes no
liability for damages, direct or consequential, which may result from
the use of DrafTools."
DrafTools(tm) is a "shareware program" and is provided at no charge to
the user for evaluation. Feel free to share it with your friends, but
please do not give it away altered or as part of another system. The
essence of "user-supported" software is to provide personal computer
users with quality software without high prices, and yet to provide
incentive for programmers to continue to develop new products. If you
find this program useful and find that you are using DrafTools(tm) and
continue to use DrafTools(tm) after a reasonable trial period, you must
make a registration payment of $25.00 (US) to Manu-Soft Computer
Services. The $25.00 registration fee will license one copy for use
on any one computer at any one time. You must treat this software
just like a book. An example is that this software may be used by any
number of people and may be freely moved from one computer location to
another, so long as there is no possibility of it being used at one
location while it's being used at another. Just as a book cannot be
read by two different persons at the same time.
Commercial users of DrafTools(tm) must register and pay for their copies
of DrafTools(tm) within 30 days of first use or their license is
withdrawn. Site-License arrangements may be made by contacting
Manu-Soft Computer Services.
Anyone distributing DrafTools(tm) for any kind of remuneration must
first contact Manu-Soft Computer Services at the address below for
authorization. This authorization will be automatically granted to
distributors recognized by the Association of Shareware Professionals
(ASP) as adhering to its guidelines for shareware distributors, and
such distributors may begin offering DrafTools(tm) immediately (However
Manu-Soft Computer Services must still be advised so that the
distributor can be kept up-to-date with the latest version of
DrafTools(tm)).
You are encouraged to pass a copy of DrafTools(tm) along to your friends
for evaluation. Please encourage them to register their copy if they
find that they can use it. All registered users will receive the
following:
The latest version of DrafTools(tm)
Unprotected source code
Free minor updates as they occur
Free technical support
Special reduced rates on major upgrades
To register, print the order form (!ORDER.FRM) and send it with check
or money order for $25.00 (US) per copy to:
DrafTools
Manu-Soft Computer Services
P.O. Box 84
Fredericksburg, OH 44627
============== DrafTools(tm) Installation & Operation Manual 3
TABLE OF CONTENTS
I. THE SHAREWARE CONCEPT 4
II. INTRODUCTION 5
III. SYSTEM REQUIREMENTS 5
IV. INSTALLATION INSTRUCTIONS 6
A. Copying Files To Your Hard Disk 6
B. Editing ACAD.MNU 7
C. Editing ACAD.LSP 8
D. Checking The Installation 9
V. GETTING STARTED 10
A. Using the Sample Title Blocks 10
B. Defining Your Own Title Block 12
C. Customizing TBLOCK.LSP 15
VI. REPORTING PROBLEMS & GETTING SUPPORT 16
VII. REGISTRATION 16
VIII. APPENDIX A--Files Included with DrafTools 17
A. Installation and Documentation 17
B. DrafTools Program Files 17
C. Sample Programs 18
IX. APPENDIX B--Global Variables 19
X. APPENDIX C--Supplied User Functions 20
============== DrafTools(tm) Installation & Operation Manual 4
I. THE SHAREWARE CONCEPT
Shareware distribution gives users a chance to try software
before buying it. If you try a Shareware program and continue
using it, you are expected to register. Individual programs
differ on details -- some request registration while others
require it, some specify a maximum trial period. With
registration, you get anything from the simple right to continue
using the software to an updated program with printed manual.
Copyright laws apply to both Shareware and commercial software,
and the copyright holder retains all rights, with a few specific
exceptions as stated below. Shareware authors are accomplished
programmers, just like commercial authors, and the programs are
of comparable quality. (In both cases, there are good programs
and bad ones!) The main difference is in the method of
distribution. The author specifically grants the right to copy
and distribute the software, either to all and sundry or to a
specific group. For example, some authors require written
permission before a commercial disk vendor may copy their
Shareware.
Shareware is a distribution method, not a type of software. You
should find software that suits your needs and pocketbook,
whether it's commercial or Shareware. The Shareware system makes
fitting your needs easier, because you can try before you buy.
And because the overhead is low, prices are low also. Shareware
has the ultimate money-back guarantee -- if you don't use the
product, you don't pay for it.
============== DrafTools(tm) Installation & Operation Manual 5
II. INTRODUCTION
DrafTools(tm) is a comprehensive set of LISP routines designed to
automate the tedious process of creating and using title blocks,
adding and updating revision blocks, and inserting tables of hole
sizes, bills-of-material, etc. This manual covers only the Custom
Title Block Management portion of DrafTools(tm). For information on
other modules please contact the author (see Section VI for address).
NOTE: This manual is intended for use by someone already
familiar with AutoCAD Release 12, AutoLISP variables, and the MSDOS
file structure. The installation process also requires the ability to
edit the ACAD.MNU file with a text editor. The recommended method is
by using Microsoft's EDIT.COM included with MSDOS 5.0 & 6.0, since
many other editors cannot load a file as large as ACAD.MNU.
III. SYSTEM REQUIREMENTS
IBM-Compatible PC with MSDOS operating system
AutoCAD Release 12/Dos, installed & running
Text editor (preferably EDIT.COM by Microsoft)
Approx. 380K Hard Disk Space
============== DrafTools(tm) Installation & Operation Manual 6
IV. INSTALLATION INSTRUCTIONS
A. Copying Files To Your Hard Disk
Before beginning the installation process, you need to decide
where on your hard disk you want to put the DrafTools Applications.
In order to keep DrafTools separate from other AutoCAD files, it is
recommended that you create a subdirectory under your AutoCAD
directory and name it DRAFTOOL. If your AutoCAD directory is C:\ACAD,
you would describe this new subdirectory by the pathname
C:\ACAD\DRAFTOOL. Here is what your directory structure might look
like after creating the DRAFTOOL subdirectory:
C:\
|--ACAD
| |--ADS
| | \--DOCS
| |--ASE
| |--DRAFTOOL <----DrafTools Directory
| |--DRV
| |--FONTS
| |--IGESFONT
| |--R11SUPP
| |--SAMPLE
| |--SOURCE
| |--SUPPORT
| \--TUTORIAL
| \--DBF
|--DOS
\--GAMES
After creating a DrafTools subdirectory, simply copy every file
from the installation diskette into the newly created subdirectory on
your hard disk. (See Appendix A for a list of files on the
installation diskette.) If you are a first time user, you should also
copy the sample files (see Appendix A, Section C for a list of sample
files) to the same newly created subdirectory on your hard disk.
============== DrafTools(tm) Installation & Operation Manual 7
B. Editing ACAD.MNU
The next step involves adding new menus to your AutoCAD menu
file. This step may not be necessary if you already have a previous
version of DrafTools installed. Check for additional instructions in
the README.DOC file on the installation diskette root directory.
The AutoCAD menu file is ACAD.MNU (unless you have customized
your menu and given it a different name) and it is located by default
in the SUPPORT subdirectory. The use of a text editor which can edit
very large files (many editors and word processors cannot load large
files like ACAD.MNU) will be required. The editor included with MSDOS
5.0 & 6.0 (EDIT.COM) works very well.
The file ACADPMNU.TXT is an ASCII file which defines a pop-up
AutoCAD menu allowing the user to execute DrafTools commands.
Following is a listing of that file:
***POP10
[DrafTools]
[Insert Title Block]^C^CINSTITLE
[ & Border]^C^CINSTITLE
[Edit Title Block]^C^CEDTITLE
[ Attributes]^C^CEDTITLE
[Define New Title]^C^CMAKEBDR
[ Block Border]^C^CMAKEBDR
To add the DrafTools pop-up menu to your menu file, ACADPMNU.TXT
must be inserted into your ACAD.MNU file after the last pop-up menu in
the file. Consult your AutoCAD manual for information on the
structure of the ACAD.MNU file. After inserting the new pop-up menu,
change the line "***POP10" to "***POPnn", where nn is the next pop-up
menu number available to you.
NOTE: To insert ACADPMNU.TXT with EDIT.COM, you first load
ACADPMNU.TXT into the editor. Then, highlight everything and pick
EDIT|COPY to copy the entire file into the EDIT Clipboard. Next, load
ACAD.MNU by picking FILE|OPEN and selecting ACAD.MNU. Once ACAD.MNU
is in the editor, you can insert the contents of the clipboard at the
cursor location by picking EDIT|PASTE.
============== DrafTools(tm) Installation & Operation Manual 8
C. Editing ACAD.LSP
The file DT_INIT.LSP must be loaded by your ACAD.LSP file. If
you don't have a file called ACAD.LSP (usually in the SUPPORT
subdirectory), you must create a new one. Using an ASCII (plain text)
editor, add the following line:
(load "C:\\ACAD\\DRAFTOOL\\DT_INIT")
Make sure the path specified points to the directory in which you
installed DrafTools. Note the "\\" (Double Backslashes).
The file DT_INIT.LSP initializes global variables and user
settings: you must edit this file to change customizable settings.
The section which merits attention (first screen) in DT_INIT.LSP looks
like this:
; ============================
; == Set Global Variables ==
; ============================
(setq *DT_PATH "c:\\acad\\draftool\\")
[Set other global variables here]
The (setq *DT_PATH... line sets the global variable *DT_PATH to the
DrafTools Subdirectory path. This variable should always be set, or
DrafTools may be unable to find required files.
You may also set the global variable *TBLAYER to the name of the
layer you want title blocks inserted on. If *TBLAYER is not defined,
"TITLE" becomes the default. You can override the layer setting
during title block insertion.
The global variable *TBSCALES is the name of the file containing
your predefined scales, and defaults to "TBSCALES" if none is
specified. TBSCALES.TBD is provided as a sample to get you started.
By setting different filenames in *TBSCALES, you can maintain multiple
predefined-scale files (possibly for different disciplines).
============== DrafTools(tm) Installation & Operation Manual 9
D. Checking The Installation
After ACAD.MNU, ACAD.LSP, and DT_INIT.LSP have been modified and
saved, start AutoCAD. Do the following tests to make sure the
installation is working properly:
A) Make sure the pop-up menu you inserted is available. It
should be the right-most pop-up menu along the top of
the screen, named 'DrafTools'. If your display
resolution is too low, you may not be able to see all
of the pop-up menus. If this is the case, rearrange
their order so that the 'DrafTools' menu is
available, or just combine two of your current pop-up
menus into one.
B) Select "Define New Title Block Border" from the
DrafTools Pop-up menu. If AutoCAD gives you an
"error: Load Failed" message, then your *DT_PATH
variable does not specify the correct pathname to
your DRAFTOOL subdirectory. Check DT_INIT.LSP and
make sure the path is correctly specified. (See the
installation instructions for further details.) You
should be greeted with a dialog box entitled "Define
New Title Block Border".
C) Pick the <Reorder and Edit Attributes> button. If you
get a dialog box entitled "Attribute Re-Order", you
can safely assume that the installation has been a
success. Press <Cancel> to exit the dialog boxes,
until you're back at the Command: prompt.
Once DrafTools is installed properly, you should read the
following sections before trying to use the DrafTools applications.
============== DrafTools(tm) Installation & Operation Manual 10
V. GETTING STARTED
A. Using the Sample Title Blocks
The easiest way to understand how a custom title block works is
to examine the sample title blocks included on the installation
diskette (C_ARCH.BDR & D_ARCH.BDR). When DrafTools looks for a title
block to insert, it looks for a file with the .BDR (for "BorDeR")
extension. A .BDR file is simply an AutoCAD drawing whose file
extension has been changed from .DWG to .BDR, thereby denoting it as a
DrafTools title block. The two sample title blocks (C_ARCH.BDR &
D_ARCH.BDR) cannot be loaded into AutoCAD directly because they have
the wrong extension; however by copying the .BDR files to .DWG files
(Ex. COPY C_ARCH.BDR C_ARCH.DWG), you can load these files into the
drawing editor like any other AutoCAD drawing. To see what the border
file is made of, do that now for C_ARCH.BDR (the C-Size border).
Load the converted drawing C_ARCH.DWG into the drawing editor.
Change your units to 'Architectural' with the UNITS command. Notice
that the lower left corner of the title block border is at the origin
(0,0,0). This corner will become the title block's insertion point.
Zoom into the title block area of the drawing, so you can see the
attributes that have been defined in the title block. You may notice
that the attributes are more representative of a Civil Engineering
drawing; however, they will nevertheless demonstate the potential of
"smart" title blocks.
Select 'Define New Title Block Border' in the DrafTools pop-up
menu, then push <Re-order and Edit Attributes>. You should be greeted
with a dialog box entitled 'Attribute Re-order'. This is the main
"Attribute Editing" dialog.
Pick the <Get All> button in the top left section of the box.
This places all "ATTDEF" entities in the 'Attributes' List Box, listed
by their "tag". Immediately after an addition to this list, all added
attributes are "selected" (highlighted): un-select them by pressing
the <Deselect All> button beneath the list box. Once no attributes
are selected ("Selected Items: None" above the list box), click on
the "DRAWING" attribute to highlight it. If this is the only
highlighted attribute ("Selected Items: 1" above the list box), then
the <Edit> button should become un-greyed. Pick the <Edit> button to
edit the selected attribute definition.
You should be presented with the 'Edit Attribute Definition'
dialog box. There are three items of interest: The Tag ("DRAWING"),
the Prompt ("Drawing Name"), and the Default ("=(getdwgname)"). The
default value is an AutoLISP function in this case. The function
(getdwgname) is defined in the sample TBLOCK.LSP file, and it returns
the current drawing file name; e.g., when this title block is
inserted the default value for this attribute will be the name of the
drawing. The process will be better understood by actually inserting
this title block. Experiment with the features in the dialog boxes to
get a feel of their functionality before continuing.
============== DrafTools(tm) Installation & Operation Manual 11
Start a new drawing named "TEST", change to Architectural units,
then select 'Insert Title Block & Border' from the DrafTools pop-up
menu. Select border 'C_ARCH' from the available list. Next, define a
new drawing scale definition for title blocks: Pick the <Add New...>
button in the 'Drawing Scale' section. For 'Scale ID' enter the text
[1" = 8'], then enter a scale of [1"]=[8'] and press <OK>. You have
just added [1" = 8'] to the list of available pre-defined scales. You
will want to add others to this list as you find you need them.
Next, pick an insertion point for the title block. Press <Pick
Point> and pick a point in the drawing area. You can press <Check It
Out> at any time after you have specified a border name to see what
the title block will look like once it's inserted: do that now.
If you are satisfied, press <OK> to insert the selected border.
You will be delivered to the standard AutoCAD attribute edit dialog to
enter attributes in the title block. If all went according to plan
the default value of the Drawing Name attribute should be "TEST", the
name of the current drawing.
Push the <Next> button to advance to the next page, and enter
"Sword Excavating" (with all lower-case except first letters of the
words) for the INSTALLER attribute. You will notice the default
values for the Installer's address and phone number are AutoLISP
functions beginning with two equal signs ('=='): such a function
calculates the attribute value after you pick the <OK> button. In
this case it will search a database of installer's names and addresses
(SSINST.DBF) for the correct values based on the entered value of the
'INSTALLER' attribute. Pick the <OK> button to insert the title block
and border into the drawing.
Once a title block is inserted, you can edit its attributes by
selecting 'Edit Title Block Attributes' from the DrafTools pop-up
menu: do this now. As you can see, the installer's name and address
are "looked up" again after you edit attributes.
Once you have a title block on screen, select 'Insert Title Block
& Border' from the DrafTools pop-up menu again. This time toggle the
'Replace Existing Title Block' button to "on" (checked). Now insert
the "D_ARCH" border over top of the "C_ARCH" border (or insert the
"C_ARCH" border at a different scale). The program looks in the
existing title block for tags of the same name as those in the
replacement, and copies their values to the new title block. If more
than one title block exists in the drawing you will be prompted to
pick the insertion point of the one you want to replace.
After inserting a title block the global variable *DWGSCALE is
set to the scale of the title block just inserted. To verify this,
type !*DWGSCALE at the Command: prompt. This global variable can be
used by user functions in "smart" attributes if they need to know the
scale factor used by the title block.
Before exiting, the title block insertion program calls the
(SETSCALES) function (in TBLOCK.LSP) to set any pertinent system or
dimensioning variables to the selected scale. Try inserting the
"C_ARCH" border at different scales and checking the DIMSCALE system
variable before and after the insertion. (For more information, see
Appendix C, Supplied User Functions.)
============== DrafTools(tm) Installation & Operation Manual 12
B. Defining Your Own Title Block
If you already use a conventional AutoCAD block as a title block,
disregard the following instructions to begin a new drawing and
instead load in your existing title block for editing. You may need
to erase your border and edit your attributes to take advantage of
DrafTools' features. If you use different borders for different paper
sizes, it is recommended that you save the attribute part of the title
block (that part which is the same in all title blocks) separately,
then use it as a starting point for drawing each size of border.
To define a new custom title block, start a new drawing and
create the title block and attributes with no border. Make sure you
are drawing on layer zero (0), so that the inserted title block will
take on the characteristics of the layer on which it is inserted. If
you are editing an existing block, make sure all entities are on layer
zero (0). If you want some entities to have different linetypes or
colors, then change that property explicitly instead of putting the
entity on a layer with the desired characteristics. This will prevent
problems in the future, as all entities in the title block will then
reside on the same layer.
First, draw all constant text and graphics entities such as
dividing lines, company logos, etc. which stay the same in every
drawing. Next, define text attributes: Select 'Re-Order Title Block
Attribs' from the 'DrafTools' pop-up menu. Pick <New> to define a new
attribute. (If you already have attributes defined, pick <Get All> to
load them into the attribute list box, then, after picking <Deselect
All>, select an attribute (shown by it's "tag") and pick <Edit> to
make any desired changes.) Following are some pointers to keep in
mind when defining attributes:
1) Give each attribute a unique tag name, so that it can be
referenced later without confusion.
2) Use the proper alignment method so that the resulting text
will be properly aligned when inserted.
3) Specify a concise prompt that will identify the attribute
when you are editing attribute values during
insertion.
4) Use a different text style for attributes and non-attribute
text. A mono-spaced font works best for attributes
because it allows you to determine a constant maximum
string length for each individual attribute based on
available space, whereas proportional spaced fonts
vary in length depending on the actual characters in
the string.
============== DrafTools(tm) Installation & Operation Manual 13
5) In order to let DrafTools do as much of your work as
possible, specify a default value for each attribute.
If the attribute value will usually be the same, use
that value as a default. You can also specify a
"dynamic default value" by using either of the
following methods:
a. precede an AutoLISP function with an equal sign
(=). The default will be the string returned by the
function at the time of insertion. This is useful,
for instance, when prompting for the drawing date:
the default value can be the current system date.
Ex. '=(menucmd "M=$(edtime,$(getvar,date),M/D/YY)")'
will return the current date as the default value.
b. precede an AutoLISP function with two equal
signs (==). This type of dynamic default value works
in a similar fashion as the one just mentioned,
except that the function does not evaluate until the
attributes have all been entered and the block is
being inserted. This is useful if the value of one
attribute depends on what was entered in another.
One example would be when an address and phone number
need to be looked up. The user would first enter a
name to use in the lookup, so the address and phone
number cannot be retrieved until the user clicks <OK>
to signify that the name has been entered. A
complete description of the LOOKUP function included
in the TBLOCK.LSP file can be found in Appendix C,
User Functions Supplied with DrafTools.
Once you have what you like, save this drawing under a name like
'TITLE', so you can use it in the borders of different drawing sizes.
HINT: If you re-order the attribute definitions before you SAVE (push
<Re-order and Edit Attributes> in the 'Define New Title Block Border'
dialog box and reorder them, then exit the dialog without creating a
border file), your attributes will appear in the correct order, and
won't need any re-ordering later.
============== DrafTools(tm) Installation & Operation Manual 14
The next step is creating a .BDR file for different drawing
sizes. Start a new drawing and give it an identifying name like "C"
or "C_GM" for the C-Size border. Make sure you are drawing on Layer
zero (0).
Starting at the UCS origin (0,0,0), draw the border for the
selected drawing size, so that 0,0,0 is the lower-left corner of the
border. Make sure that you draw the border at a scale of 1:1, so that
one drawing unit is equal to 1 plotted unit. For example, if your
plotter's maximum plotting size for a C-Size sheet is 32.0" x 20.0"
and your drawing dimensions are in inches then your border should be
32.0 drawing units by 20.0 drawing units in size.
Once you have your border, insert the drawing of your title block
attributes at its proper position in the border. Check the attribute
prompts and default values to make sure they are satisfactory, but
don't bother entering any attribute values. Explode the attribute
block once it is positioned where you want it. When the block is
exploded, the attributes it contained will display as attribute tags
and attribute values will be lost.
Now select 'Define New Title Block Border' from the 'DrafTools'
pop-up menu, and push <Re-order and Edit Attributes>. This gives you
an opportunity to check the order of the attributes and to make any
modifications for this particular border size. Once you are
satisfied, exit the 'Attribute Re-order' dialog by pushing either
<Reorder> or <Cancel>. Push <Create New Border> in the main dialog
and enter the new border's filename when asked. You now have a new
border available when you try to insert a new title block! Try
inserting the new border, and see if it works.
============== DrafTools(tm) Installation & Operation Manual 15
C. Customizing TBLOCK.LSP
The file TBLOCK.LSP is a SAMPLE file which contains a number of
functions used by the sample title blocks C_ARCH.BDR & D_ARCH.BDR. It
also contains the (SETSCALES) function, which is evaluated each time a
new title block is inserted.
The sample TBLOCK.LSP file should be customized to fit your
needs: delete any functions you don't need, and edit the (SETSCALES)
function to change variables such as DIMSCALE, TEXTSIZE, etc. to your
desired value, based on the entered drawing scale which is passed to
the function by the title block program.
NOTE: the 'scale' argument passed to (SETSCALES) is the inverse
of the specified drawing scale. This allows you to use 'scale' as a
multiplier when setting variables (that is, 'scale' can be multiplied
by a constant to return the appropriate value).
Ex.:
If 'Scale Factor' was 1" = 8'
then 'scale' will be 96 (8'/1" = 96")
If 'Scale Factor' was 1 = 2
then 'scale' will be 2 (2/1 = 2)
============== DrafTools(tm) Installation & Operation Manual 16
VI. REPORTING PROBLEMS & GETTING SUPPORT
Any problems with this software can be reported to the author via
CompuServe:
Owen Wengerd
71324,3252
or via mail:
DrafTools
Manu-Soft Computer Services
P.O. Box 84
Fredericksburg, OH 44627
or via phone:
(216) 695-5903
(Call eves or leave name, phone number, & time to return call)
It is the author's desire to make this software as easy to use as
possible. However, to make use of it's advanced features requires
some AutoLISP experience. If you need help in that area it is
recommended that you find someone in your area who can get you started
in AutoLISP programming: the benefits of learning to program in
AutoLISP will be well worth the effort.
VII. REGISTRATION
You are encouraged to pass a copy of DrafTools(tm) along to your
friends for evaluation. Please encourage them to register their copy
if they find that they can use it. All registered users will receive
the following:
The latest version of DrafTools(tm)
Unprotected source code
Free minor updates as they occur
Free technical support
Special reduced rates on major upgrades
To register, print the order form (!ORDER.FRM) and send it with check
or money order for $25.00 (US) per copy to:
DrafTools
Manu-Soft Computer Services
P.O. Box 84
Fredericksburg, OH 44627
============== DrafTools(tm) Installation & Operation Manual 17
VIII. APPENDIX A--Files Included with DrafTools
A. Installation and Documentation
README .DOC Start-up instructions & last minute details.
!LICENSE.DOC Licence, registration, and ordering instructions.
!ORDER .DOC Order form.
!PACKING.LST List of included files.
!MANUAL .TXT This users manual. Plain text format for on-line
viewing.
!MANUAL .PRN This users manual. COPY this file to any printer for a
printed manual.
ACADPMNU.TXT This ASCII file defines the pop-up DrafTools menu, and
must be inserted into your ACAD.MNU file.
B. DrafTools Program Files
DT_INIT .LSP This file defines custom settings and initializes
DrafTools. It must be loaded by your ACAD.LSP file.
MAKEBDR .LSP AutoLISP program that creates a new Title Block Border.
MAKEBDR .DCL Dialog box definition (DCL) file used by MAKEBDR.LSP.
INSTITLE.LSP AutoLISP program that inserts a new title block into a
drawing.
INSTITLE.DCL Dialog box definition (DCL) file used by INSTITLE.LSP.
INSTITLE.HLP On-line help text for INSTITLE.LSP (AutoCAD help file
format).
EDTITLE .LSP AutoLISP program that allows attribute value editing of
a previously inserted title block.
EDATTRIB.LSP AutoLISP program for editing attribute definitions.
EDATTRIB.DCL Dialog box definition (DCL) file used by EDATTRIB.LSP.
EDATTRIB.HLP On-line help text for EDATTRIB.LSP (AutoCAD help file
format).
RE-ORDER.LSP AutoLISP program for re-ordering and editing attribute
definitions.
============== DrafTools(tm) Installation & Operation Manual 18
RE-ORDER.DCL Dialog box definition (DCL) file used by RE-ORDER.LSP.
RE-ORDER.HLP On-line help text for RE-ORDER.LSP (AutoCAD help file
format).
XDOS_DT .C Source code for XDOS_DT.EXP (ADS application).
XDOS_DT .EXP ADS application used by DrafTools for performing DOS
file functions from within AutoCAD. This routine was
adapted from AutoDesk's XDOS utility.
C. Sample Programs
TBLOCK .DWG Sample title block design.
C_ARCH .BDR Sample C-Size Title Block using TBLOCK.DWG.
D_ARCH .BDR Sample D-Size Title Block using TBLOCK.DWG.
TBLOCK .LSP AutoLISP functions required by TBLOCK.DWG.*
SSINST .DBF DBase file containing names and addresses of septic
system installers--used by sample title blocks.
SSINST .ASC ASCII file of contents of SSINST.DBF, included only to
show contents of DBase file.
* DrafTools programs look for and load a file named TBLOCK.LSP
before inserting or editing a title block. This file
contains the (SETSCALES) function (see Appendix C,
Supplied User Functions) as well as any functions
required by "dynamic default values". However, if a
function is only required by one particular title
block it can be defined in xxxxxxxx.LSP where
xxxxxxxx is the name of the title block xxxxxxxx.BDR
file that uses it. (That is, if you insert C.BDR,
the file C.LSP will be loaded if it exists.)
============== DrafTools(tm) Installation & Operation Manual 19
IX. APPENDIX B--Global Variables
*DT_PATH . . . . Pathname of DrafTools subdirectory.
Ex. "C:\\ACAD\\DRAFTOOL\\"
*DWGSCALE . . . . Current Default Drawing Scale, set by specifying a
drawing scale during title block insertion.
*TBLAYER . . . . String variable specifying name of layer for Title
Blocks. Default layer is "TITLE" if none specified.
*TBSCALES . . . . String variable specifying name of file to use for
storing predefined drawing scales. Default filename
is "TBSCALES.TBD" if none specified.
Note: All Global variables that need to be set should be set in the
DT_INIT.LSP file with the following AutoLISP command:
(setq VARIABLE VALUE) where VARIABLE is the variable
name and VALUE is its desired value. String values
must be specified in double quotes ("").
============== DrafTools(tm) Installation & Operation Manual 20
X. APPENDIX C--Supplied User Functions
* All User functions are supplied AS SAMPLES ONLY, and reside in
TBLOCK.LSP (see above)
(SETSCALES scale)--This function is used to set system and dimension
variables after a drawing scale has been determined.
It is automatically called by DrafTools when
inserting a new title block. This function may be
edited to set variables as desired.
(getdwgname)--Returns the name of the current drawing or the empty
string ("") if the drawing is unnamed.
(getattribval ent tag)--Returns a string, the 'value' of an attribute,
where "ent" is the entity name of the block
containing the attribute and "tag" is the attribute
tag.
(pack string)--Returns string "string" with trailing spaces removed.
(lookup dbase tag index field)--Returns the contents of field "field"
from a dbase .dbf file (database) in the record where
the contents of the "index" field are equal to the
current value of the attribute "tag". This function
is used to look up an address, for example, when
another attribute contains the name of the person for
whom you want an address.
Example: (lookup "SSINST.DBF" "INSTALLER" "NAME"
"PHONE")